﻿@using Microsoft.AspNetCore.Http
@inject IHttpContextAccessor httpContextAccessor


<div class="top-row pl-4 navbar navbar-dark">
    <a class="navbar-brand" href="">AGV呼叫系统</a>
    <button class="navbar-toggler" @onclick="ToggleNavMenu">
        <span class="navbar-toggler-icon"></span>
    </button>
</div>


<div class="@NavMenuCssClass" @onclick="ToggleNavMenu">
    <LoginControl />
    <ul class="nav flex-column">
        @*<li class="nav-item px-3">
            <NavLink class="nav-link" href="RawPage" Match="NavLinkMatch.All">
                <span class="oi " aria-hidden="true">
                    <img src="数据显示.png" style="width:20px;height:20px" />
                </span> 生箔下料
            </NavLink>
        </li>
        <li class="nav-item px-3">
            <NavLink class="nav-link" href="OvenUp">
                <span class="oi " aria-hidden="true">
                    <img src="缓存区设置.png" style="width:20px;height:20px" />
                </span> 缓存区进烘箱
            </NavLink>
        </li>
        <li class="nav-item px-3">
            <NavLink class="nav-link" href="OvenPage">
                <span class="oi " aria-hidden="true">
                    <img src="AGV数据.png" style="width:20px;height:20px" />
                </span> 烘箱出料
            </NavLink>
        </li>
        <li class="nav-item px-3">
            <NavLink class="nav-link" href="SlittingmachineUp">
                <span class="oi " aria-hidden="true">
                    <img src="任务列表.png" style="width:20px;height:20px" />
                </span> 分切机上料
            </NavLink>
        </li>
        <li class="nav-item px-3">
            <NavLink class="nav-link" href="SlittingmachineDown">
                <span class="oi " aria-hidden="true">
                    <img src="历史任务.png" style="width:20px;height:20px" />
                </span> 分切机下料
            </NavLink>
        </li>
        <li class="nav-item px-3">
            <NavLink class="nav-link" href="WasteGetPage">
                <span class="oi " aria-hidden="true">
                    <img src="缓存架设置.png" style="width:20px;height:20px" />
                </span> 废箔转运
            </NavLink>
        </li>
        <li class="nav-item px-3">
            <NavLink class="nav-link" href="UPdatadetecPage">
                <span class="oi " aria-hidden="true">
                    <img src="缓存架设置.png" style="width:20px;height:20px" />
                </span> 更新一次包装数据
            </NavLink>
        </li>
        <li class="nav-item px-3">
            <NavLink class="nav-link" href="FinshedGet">
                <span class="oi " aria-hidden="true">
                    <img src="缓存架设置.png" style="width:20px;height:20px" />
                </span> 成品转运
            </NavLink>
        </li>
        <li class="nav-item px-3">
            <NavLink class="nav-link" href="FinshedGetEmpty">
                <span class="oi " aria-hidden="true">
                    <img src="缓存架设置.png" style="width:20px;height:20px" />
                </span> 空工装转运
            </NavLink>
        </li>*@
        
        @*<li class="nav-item px-3">
            <NavLink class="nav-link" href="MaterialTypePage">
                <span class="oi " aria-hidden="true">
                    <img src="缓存区设置.png" style="width:20px;height:20px" />
                </span> 物料类型设置
            </NavLink>
        </li>*@
        @*<li class="nav-item px-3">
            <NavLink class="nav-link" href="BusinessDepartmentPage">
                <span class="oi " aria-hidden="true">
                    <img src="业务部设置.png" style="width:20px;height:20px" />
                </span> 业务部设置
            </NavLink>
        </li>*@


        <li class="nav-item px-3">
           @* <NavLink class="nav-link" href="RkPage">
                <span class="oi " aria-hidden="true">
                    <img src="缓存架设置.png" style="width:20px;height:20px" />
                </span> 成品转运
            </NavLink>
            <NavLink class="nav-link" href="CKPage">
                <span class="oi " aria-hidden="true">
                    <img src="缓存架设置.png" style="width:20px;height:20px" />
                </span> 成品出库
            </NavLink>*@
            <NavLink class="nav-link" href="CreatCKD">
                <span class="oi " aria-hidden="true">
                    <img src="缓存架设置.png" style="width:20px;height:20px" />
                </span> 出库扫码验证
            </NavLink>
            <NavLink class="nav-link" href="CKNOUpdataPage">
                <span class="oi " aria-hidden="true">
                    <img src="缓存架设置.png" style="width:20px;height:20px" />
                </span> 查看出库单未扫码的数据
            </NavLink>
            
            <NavLink class="nav-link" href="CreatRDK">
                <span class="oi " aria-hidden="true">
                    <img src="缓存架设置.png" style="width:20px;height:20px" />
                </span> 手动更新入库单
            </NavLink>
@*            <NavLink class="nav-link" href="XSCKDPage">
                <span class="oi " aria-hidden="true">
                    <img src="缓存架设置.png" style="width:20px;height:20px" />
                </span> 暂存销售出库单集合
            </NavLink>*@
            <NavLink class="nav-link" href="PDPage">
                <span class="oi " aria-hidden="true">
                    <img src="缓存架设置.png" style="width:20px;height:20px" />
                </span> 盘点
            </NavLink>

            <NavLink class="nav-link" href="PDNOUpdataPage">
                <span class="oi " aria-hidden="true">
                    <img src="缓存架设置.png" style="width:20px;height:20px" />
                </span> 查看盘点未录入数据
            </NavLink>
            
        </li>
        <li class="nav-item px-3">
             <NavLink class="nav-link" >
                <span class="oi oi-list-rich" aria-hidden="true"></span>
                当前用户：@httpContextAccessor.HttpContext.User.FindFirst("employeeName").Value
            </NavLink>
         
                

            
        </li>
        <li class="nav-item px-3">
            <NavLink class="nav-link" href="/logout?returnUrl=/">
                <span class="oi " aria-hidden="true">
                    <img src="退出.png" style="width:20px;height:20px" />
                </span> 退出
            </NavLink>
        </li>
    </ul>
</div>

@code {
    private bool collapseNavMenu = true;
    private string UserName;
    private string NavMenuCssClass => collapseNavMenu ? "collapse" : null;

    private void ToggleNavMenu()
    {
        collapseNavMenu = !collapseNavMenu;
    }
}
